<?php

namespace app\store\controller;

use think\Controller;
use think\Exception;

class Api extends Controller
{
    /**
     * 微信图片上传相关
     * HYF
     */
    public function tempfile()
    {
        $mid = input('mid');
        $weixin = new Weixin(input("shop_id",0));
        $file_name = $weixin->getTempFile($mid);

        if ($file_name) {
            $this->success('success', '', $file_name);

        }
        $this->error('error', '', $file_name);

    }

    public function tempfile2()
    {
        $mid = input('mid');
        $weixin = new Weixin(input('shop_id',0));
        $file_name = $weixin->getTempFile2($mid);

        if ($file_name) {
            $this->success('success', '', $file_name);

        }
        $this->error('error', '', $file_name);

    }



}
